package com.vdong.trade.trading.facade.enums;

/**
 * 提现订单状态枚举
 */
public enum WithdrawStatusEnum {
    WITHDRAW_INIT("0", "申请提现"),
    WITHDRAW_SUCCESS("1", "提现成功"),
    WITHDRAW_FAIL("2", "提现失败"),
    WITHDRAW_SYSTEM_ERROR("3", "第三方支付异常,待确认"),

    ;

    WithdrawStatusEnum(String status, String value) {
        this.status = status;
        this.value = value;
    }

    private final String status;
    private final String value;

    public String getStatus() {
        return status;
    }

    public String getValue() {
        return value;
    }

    public static String getEnumValue(String status) {
        for (WithdrawStatusEnum statusEnum : WithdrawStatusEnum.values()) {
            if (statusEnum.getStatus().equals(status)) {
                return statusEnum.value;
            }
        }
        return null;
    }
}
